/*
 * Powered By [rapid-framework]
 * Web Site: http://www.rapid-framework.org.cn
 * Google Code: http://code.google.com/p/rapid-framework/
 * Since 2008 - 2018
 */

package com.hzyb.shopCart.model;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

import org.hibernate.annotations.GenericGenerator;
import org.hibernate.validator.constraints.Length;

/**
 * @author badqiu email:badqiu(a)gmail.com
 * @version 1.0
 * @since 1.0
 */


@Entity
@Table(name = "shop_cart")
public class ShopCart {
	
	

	//可以直接使用: @Length(max=50,message="用户名长度不能大于50")显示错误消息
	//columns START
	@Length(max=50)
	private java.lang.String cartSid;
	@Length(max=50)
	private java.lang.String commoditySid;
	@Length(max=20)
	private java.lang.String size;
	@Length(max=20)
	private java.lang.String color;
	@Length(max=300)
	private java.lang.String name;
	
	private java.util.Date enterDate;
	@Length(max=300)
	private java.lang.String enterUserid;
	
	private java.util.Date updateDate;
	@Length(max=50)
	private java.lang.String updateUserid;
	
	private java.lang.Integer num;
	@Length(max=50)
	private java.lang.String userid;
	@Length(max=50)
	private java.lang.String fileId;
	//columns END


	public ShopCart(){
	}

	public ShopCart(
		java.lang.String cartSid
	){
		this.cartSid = cartSid;
	}

	

	public void setCartSid(java.lang.String value) {
		this.cartSid = value;
	}
	
	@Id @GeneratedValue(generator="custom-id")
	@GenericGenerator(name="custom-id", strategy = "uuid")
	@Column(name = "cart_sid", unique = true, nullable = false, insertable = true, updatable = true, length = 50)
	public java.lang.String getCartSid() {
		return this.cartSid;
	}
	
	@Column(name = "commodity_sid", unique = false, nullable = true, insertable = true, updatable = true, length = 50)
	public java.lang.String getCommoditySid() {
		return this.commoditySid;
	}
	
	public void setCommoditySid(java.lang.String value) {
		this.commoditySid = value;
	}
	
	@Column(name = "size", unique = false, nullable = true, insertable = true, updatable = true, length = 20)
	public java.lang.String getSize() {
		return this.size;
	}
	
	public void setSize(java.lang.String value) {
		this.size = value;
	}
	
	@Column(name = "color", unique = false, nullable = true, insertable = true, updatable = true, length = 20)
	public java.lang.String getColor() {
		return this.color;
	}
	
	public void setColor(java.lang.String value) {
		this.color = value;
	}
	
	@Column(name = "name", unique = false, nullable = true, insertable = true, updatable = true, length = 300)
	public java.lang.String getName() {
		return this.name;
	}
	
	public void setName(java.lang.String value) {
		this.name = value;
	}
	
	
	
	@Column(name = "enter_date", unique = false, nullable = true, insertable = true, updatable = true, length = 0)
	public java.util.Date getEnterDate() {
		return this.enterDate;
	}
	
	public void setEnterDate(java.util.Date value) {
		this.enterDate = value;
	}
	
	@Column(name = "enter_userid", unique = false, nullable = true, insertable = true, updatable = true, length = 300)
	public java.lang.String getEnterUserid() {
		return this.enterUserid;
	}
	
	public void setEnterUserid(java.lang.String value) {
		this.enterUserid = value;
	}
	
	
	
	@Column(name = "update_date", unique = false, nullable = true, insertable = true, updatable = true, length = 0)
	public java.util.Date getUpdateDate() {
		return this.updateDate;
	}
	
	public void setUpdateDate(java.util.Date value) {
		this.updateDate = value;
	}
	
	@Column(name = "update_userid", unique = false, nullable = true, insertable = true, updatable = true, length = 50)
	public java.lang.String getUpdateUserid() {
		return this.updateUserid;
	}
	
	public void setUpdateUserid(java.lang.String value) {
		this.updateUserid = value;
	}
	
	@Column(name = "num", unique = false, nullable = true, insertable = true, updatable = true, length = 10)
	public java.lang.Integer getNum() {
		return this.num;
	}
	
	public void setNum(java.lang.Integer value) {
		this.num = value;
	}
	
	@Column(name = "userid", unique = false, nullable = true, insertable = true, updatable = true, length = 50)
	public java.lang.String getUserid() {
		return this.userid;
	}
	
	public void setUserid(java.lang.String value) {
		this.userid = value;
	}
	
	@Column(name = "file_id", unique = false, nullable = true, insertable = true, updatable = true, length = 50)
	public java.lang.String getFileId() {
		return this.fileId;
	}
	
	public void setFileId(java.lang.String value) {
		this.fileId = value;
	}
}

